#pragma once
#include "StdAfx.h"
#include "PowerFlow_Mo.h"

class POWERFLOW_MO StringUtils
{
public:
	static string Int2String(int nValue,int nPrecision=20);
	static string Double2String(double dValue,int nPrecision=20);
	static string Vector2String(vector<int> vVlus,string sSeparator,int nPrecision=20 );
	static string Vector2String(vector<double> vVlus,string sSeparator,int nPrecision=20 );
	static string Bool2String(bool bValue);
	static bool String2Bool(string sValue);

public:
	static wstring StringToWString(string sInput);
	static string WStringToString(wstring sInput);
	static char* WcharToChar(const wchar_t* wp);
	static wchar_t* CharToWchar(const char* c);
	static string GBKToUTF8(const std::string& strGBK);
	static string UTF8ToGBK(const std::string& strUTF8);

	static int CStringToStdstring(CString &szCStr, string &sStdstr);
};

